/******************************************************************************
 * RLT DSP
 * by Roberto Bender <beto.bender@gmail.com>
 * under GPL 2.0 license
 * 2009
******************************************************************************/

#include "distortion.h"
#include "defines.h"

workingWord distortion(workingWord input, struct FilterParams* params)
{
    workingWord output = input;
    
    if(output > (params->m_AmpCrop)) output = params->m_AmpCrop;
    if(output < -(params->m_AmpCrop)) output = -params->m_AmpCrop;

    return output;
}

